/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package controller;

import controller.service.BillControllerService;
import java.util.Date;
import java.util.List;
import model.dao.BillDAO;
import model.dao.service.BillDAOService;
import model.entities.Bill;

/**
 *
 * @author K u Ku
 */
public class BillController implements BillControllerService {
    private static BillController bill;
    public static BillController getInstance(){
        if(bill == null){
            bill = new BillController();
        }
        return bill;
    }
    
    private BillDAOService bll = new BillDAO();
    @Override
    public List<Bill> getBillList() {
        return bll.getBillList();
    }

    @Override
    public Bill getBillByID(int billID) {
        return bll.getBillByID(billID);
    }

    @Override
    public boolean insertBillDAO(Bill bill) {
        return bll.insertBillDAO(bill);
    }

    @Override
    public boolean updateBillDAO(Bill bill) {
        return bll.updateBillDAO(bill);
    }

    @Override
    public boolean deleteBillDAO(int billID) {
        return bll.deleteBillDAO(billID);
    }

    @Override
    public List<Bill> findBillByID(int billId) {
        return bll.findBillByID(billId);
    }

    @Override
    public List<Bill> findBillByDate(Date date) {
        return bll.findBillByDate(date);
    }

    @Override
    public List<Bill> findBillByUserID(int userID) {
        return bll.findBillByUserID(userID);
    }

    @Override
    public List<Bill> getBillsByUserID(int userID) {
        throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
    }

    @Override
    public List<Bill> getBillsByStudentID(int studentID) {
        throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
    }

    @Override
    public List<Bill> getBillsByCourseID(int courseID) {
        throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
    }

}
